﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using GLImp;
using CastleOfTheDisillusioned.Weapons;
using CastleOfTheDisillusioned.Input;
using CastleOfTheDisillusioned.Location;

namespace CastleOfTheDisillusioned {
	class PauseMenu {
		int Selection = 0;
		
		public void Update() {
			if (Controls.IsPressed(Control.Down)) {
				Selection += 1;
			}

			if (Controls.IsPressed(Control.Up)) {
				Selection -= 1;
			}

			if (Controls.IsPressed(Control.Accept)) {
				if (Selection == 0) {
					Location_State.CurrentPlayer.CurrentWeapon = new Whip();
				}

				if (Selection == 1) {
					Location_State.CurrentPlayer.CurrentWeapon = new GreatAxe();
				}

				if (Selection == 2) {
					Location_State.CurrentPlayer.CurrentWeapon = new Spear();
				}
			}
		}

		public void Draw() {
			GraphicsManager.DrawString(40, 100, "Equip Whip");
			GraphicsManager.DrawString(40, 120, "Equip Great Axe");
			GraphicsManager.DrawString(40, 140, "Equip Spear");

			GraphicsManager.DrawString(20, 100 + (Selection * 20), ">");
		}
	}
}
